http://junkcharts.typepad.com/junk_charts/2012/05/spring-flowers-and-striking-hours.html
June 9, 2015
http://junkcharts.typepad.com/junk_charts/2012/05/spring-flowers-and-striking-hours.html
Graphics consist of
Both the structure and aesthetics should help viewers interpret the information.
Can you spot the odd one out?
    Â
nice applet by Chris Healey
Color is stronger than shape
Combination of pre-attentive features is usually not pre-attentive due to interference.
Can you spot the odd one out?
    Â
Features in ggplot2 are called aesthetics
main ones: colour, size, shape, alpha value
… let's play with them a bit …
Find ways to improve the following graphic:
interaction combines factor variablesframe <- data.frame(x=runif(25), y=runif(25),
g1=rep(c("A","B"), c(12,13)),
g2=rep(c("1", "2"), c(13,12)))
qplot(x,y, shape=g1, colour=g2, data=frame, size=I(4))
The exact same hue and intensity in one situation may appear to be a different color in a different context.
A and B are the same intensity and hue, but appear to be different.
Which is bigger?
  Â
  Â
from ggplot2's online help
Quantitative schemes:
use color gradient with only one hue for positive values
Small objects or thin lines need more contrast than larger areas
R package based on Cynthia Brewer's color schemes ColorBrewer2.org
install.packages("RColorBrewer")
library(RColorBrewer)
help(package=RColorBrewer)
display.brewer.all()
factor variable: scale_colour_discrete, scale_colour_brewer(palette=...)
continuous variable:
scale_colour_gradient (define low, high values)
scale_colour_gradient2 (define low, mid, and high values)
scale_fill_XXXdata(diamonds)
qplot(carat, price, shape=cut, colour=clarity,
data=diamonds)
facets = row ~ col Use . if there is no variable for either row or column (i.e. facets = . ~ col)qplot(price, carat, data=diamonds, color=color,
facets = . ~ clarity)
The movies dataset contains information from IMDB.com including ratings, genre, length in minutes, and year of release.
Explore the differences in length, rating, etc. in movie genres over time
Hint: use facetting!